package kr.hkit.powerjava.chapter21;

import java.util.Scanner;

public class DivideByZeroOK {
	public static void main(String[] args) {
		int x;
		int y;
		Scanner sc = new Scanner(System.in);
		System.out.print("피젯수 : ");
		x = sc.nextInt();
		System.out.print("젯수 : ");
		y = sc.nextInt();
		
		try{
		int result = x / y;
		}catch(ArithmeticException e){
			System.out.println("0으로 나눌수 없습니다.");
			e.printStackTrace();
		}finally{
			System.out.println("프로그램 계속 진행");
		}
	}
}
